package com.springmvc2.controller;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import com.springmvc2.mapper.UserMapper;

@RestController
public class TestController {
	
	@Autowired
	UserMapper userMapper;
	
	
	@RequestMapping("/")
	public String index() {
		return "mm";
	}
	
	@RequestMapping("/order")
	public int user() {
		
		
		List<?>ls=userMapper.getAllUser();
		
		
		return ls.size();
	}
}
